<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.17"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>libwkhtmltox: Main Page</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">libwkhtmltox
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.17 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="PageDoc"><div class="header">
  <div class="headertitle">
<div class="title">libwkhtmltox Documentation</div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><p>libwkhtmltox is divided into several parts.</p>
<h1><a class="anchor" id="PDFH"></a>
To PDF c-bindings</h1>
<p>The file <a class="el" href="pdf_8h.html">pdf.h</a> contains a fairly high level and stable pure c binding to wkhtmltopdf. These binding are well documented and do not depend on QT. Using this is the recommended way of interfacing with the PDF portion of libwkhtmltox.</p>
<p>Using these binding it is relatively straight forward to convert one or more HTML document to a PDF file, using the following process:</p>
<ul>
<li>wkhtmltopdf_init is called.</li>
<li>A <a class="el" href="structwkhtmltopdf__global__settings.html">wkhtmltopdf_global_settings</a> object is creating by calling wkhtmltopdf_create_global_settings.</li>
<li>Non web page specific <a class="el" href="pagesettings.html">Setting</a> for the conversion are set by multiple calls to wkhtmltopdf_set_global_setting.</li>
<li>A <a class="el" href="structwkhtmltopdf__converter.html">wkhtmltopdf_converter</a> object is created by calling wkhtmltopdf_create_converter, which consumes the global_settings instance.</li>
<li>A number of object (web pages) are added to the conversion process, this is done by<ul>
<li>Creating a <a class="el" href="structwkhtmltopdf__object__settings.html">wkhtmltopdf_object_settings</a> instance by calling wkhtmltopdf_create_object_settings.</li>
<li>Setting web page specific <a class="el" href="pagesettings.html">Setting</a> by multiple calls to wkhtmltopdf_set_object_setting.</li>
<li>Adding the object to the conversion process by calling wkhtmltopdf_add_object</li>
</ul>
</li>
<li>A number of callback function are added to the converter object.</li>
<li>The conversion is performed by calling wkhtmltopdf_convert.</li>
<li>The converter object is destroyed by calling wkhtmltopdf_destroy_converter.</li>
</ul>
<h1><a class="anchor" id="IMAGEH"></a>
To image c-bindings</h1>
<p>The file image.h contains a fairly high level and stable pure c binding to wkhtmltoimage. These binding are well documented and do not depend on QT. Using this is the recommended way of interfacing with the image portion of libwkhtmltox.</p>
<p>Using these binding it is relatively straight forward to convert one or more HTML document to a raster image or SVG document, using the following process:</p>
<ul>
<li>wkhtmltoimage_init is called.</li>
<li>A wkhtmltoimage_global_settings object is creating by calling wkhtmltoimage_create_global_settings.</li>
<li><a class="el" href="pagesettings.html">Setting</a> for the conversion are set by multiple calls to wkhtmltoimage_set_global_setting.</li>
<li>A wkhtmltoimage_converter object is created by calling wkhtmltoimage_create_converter, which consumes the global_settings instance.</li>
<li>A number of callback function are added to the converter object.</li>
<li>The conversion is performed by calling wkhtmltoimage_convert.</li>
<li>The converter object is destroyed by calling wkhtmltoimage_destroy_converter.</li>
</ul>
<h1><a class="anchor" id="RESTH"></a>
The rest of the headers.</h1>
<p>The rest of the headers directly exposes the C++ QT dependent class used internally by wkhtmltopdf and wkhtmltoimage. They are not fairly well documented and are not guaranteed to remain stable. unless you know what you are doing you should not use these bindings. </p>
</div></div><!-- PageDoc -->
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.17
</small></address>
</body>
</html>
